﻿@model LayuiMvcUtil.Result.DataResult<LayuiMvc.DataModel.Community.UserCenterModel>

<!--用户信息-->
<div class="fly-home fly-panel">
    <img src="@Model.data.HeadImgUrl"  />
    @if (Model.data.IsApprove)
    {
        <i class="iconfont icon-renzheng" title="社区认证"></i>
    }
    <h1>
        @Model.data.NickName
        @if (Model.data.Sex==10)
        {
            <i class="iconfont icon-nan"></i>
        }
        @if (Model.data.Sex==20)
        {
            <i class="iconfont icon-nv"></i>
        }

        <i class="layui-badge fly-badge-vip">@Model.data.UserIdentityStr</i>
    </h1>

    @if (Model.data.IsApprove)
    {
        <p style="padding:10px 0; color:#5FB878;">认证信息:@Model.data.ApproveMsg</p>
    }
    <p class="fiy-home-info">
        <i class="iconfont icon-shijian"></i>
        <span>@Model.data.RegisterTime.ToString("yyyy-MM-dd") 加入</span>
    </p>

    <p class="fly-home-sign">@Model.data.Instrduce</p>
</div>

<!--用户的发布以为对应的回帖信息-->
<div class="layui-container">
    <div class="layui-row layui-col-space15">

        <!--用户的发布-->
        <div class="layui-col-xs6 fly-home-jie">
            <div class="fly-panel">
                <h3 class="fly-panel-title">
                    @Model.data.NickName 最近的发布
                </h3>
                <ul class="jie-row">
                    @foreach(var publish in Model.data.PublishList)
                    {
                        <li>
                            <!--判断帖子状态-->
                            @if (publish.IsTop)
	                        {
		                         <span class="layui-badge layui-bg-black">顶</span>
	                        }
                            @if (publish.IsCream)
	                        {
		                         <span class="layui-badge layui-bg-red">精</span>
	                        }

                                 <a href="@Url.Action("Detail","Post",new {postId=publish.PostId })" class="jie-title">@publish.Title</a>
                                <i>@publish.PublishTimeSpan</i>
                            <em class="layui-hide-xs">@publish.ViewCount 阅/@publish.ReplyCount 答</em>
                        </li>
                    }
                </ul>
                @if (Model.data.PublishList.Count==0)
                {
                <div class="fly-none" style="min-height:50px;padding:30px 0; height:auto;"><i style="font-size:14px;">没有发表任何帖子</i></div>
                }
            </div>
        </div>
        <!--用户的回复-->
        <div class="layui-col-xs6 fly-home-da">
            <div class="fly-panel">
                <h3 class="fly-panel-title">
                    @Model.data.NickName 最近的回复
                </h3>
                <ul class="home-jieda">
                    @foreach (var reply in Model.data.ReplyList)
                    {
                        <li>
                            <p>
                                <span>@reply.ReplyTimeTimeSpan</span>
                                在<a href="@Url.Action("Detail","Post",new {postId=reply.PostId })" class="jie-title">@reply.Title</a>
                            </p>
                            <div class="home-dacontent">
                                @Html.Raw(reply.HtmlContent)
                            </div>
                        </li>
                    }

                </ul>
                @if (Model.data.ReplyList.Count == 0)
                {
                    <div class="fly-none" style="min-height:50px; padding:30px 0; height:auto;"><span>没有回复任何问题</span></div>
                }
            </div>
        </div>

    </div>
</div>